<template>
  <div class="dashboard-container">
    <div style="margin: 100px auto 0; width: 1000px">
      <div class="pb-4">
        <span style="font-size:24px">今日概况</span>
        <!-- <i style="font-size:20px; cursor: pointer" class="el-icon-refresh-left ml-5" @click="getHomeList"></i> -->
      </div>
      <el-table :data="list" border>
        <el-table-column prop="name" label="" />
        <el-table-column prop="newCount" label="新申请" />
        <el-table-column prop="helpCount" label="协助" />
        <el-table-column prop="againCount" label="再分配" />
        <!-- <el-table-column prop="appointmentCount" label="预约上门" />
        <el-table-column prop="upCount" label="上门数" /> -->
        <el-table-column prop="contractCount" label="签约数" />
        <el-table-column prop="importCount" label="进件数" />
        <!-- <el-table-column prop="depositAmount" label="诚意金" /> -->
        <el-table-column prop="depositAmount" label="佣金" />
        <el-table-column prop="incomeAmount" label="已收金额" />
        <el-table-column prop="shengyu" label="未收金额" />
        <el-table-column prop="callRate" label="接通率" />
        <el-table-column prop="fitRate" label="有效率" />
      </el-table>
    </div>
  </div>
</template>

<script>
import { getHomeList } from "@/api/user";
export default {
  name: "Dashboard",
  data() {
    return {
      list: [],
    };
  },
  created() {
    this.getHomeList();
  },
  methods: {
    async getHomeList() {
      this.showAppLoading();
      const res = await getHomeList();
      this.hideAppLoading();
      if (!res.result) return;
      this.list = res.data;
    },
  },
};
</script>
